package model;

public class Result {
	private String algorithm;
	private String a;
	private String b;
	private String solution;
	private long duration;
	private long space;
	
	public Result(String algorithm, String a, String b, String solution,long duration,long space) {
		this.setAlgorithm(algorithm);
		this.setA(a);
		this.setB(b);
		this.setSolution(solution);
		this.setDuration(duration);
		this.setSpace(space);
	}
	
	public String getAlgorithm() {
		return algorithm;
	}
	public void setAlgorithm(String algorithm) {
		this.algorithm = algorithm;
	}
	public String getA() {
		return a;
	}
	public void setA(String a) {
		this.a = a;
	}
	public String getB() {
		return b;
	}
	public void setB(String b) {
		this.b = b;
	}
	public String getSolution() {
		return solution;
	}
	public void setSolution(String solution) {
		this.solution = solution;
	}
	public long getDuration() {
		return duration;
	}
	public void setDuration(long duration) {
		this.duration = duration;
	}
	public long getSpace() {
		return space;
	}
	public void setSpace(long space) {
		this.space = space;
	}

	public int getProblemLength() {
		return Math.max(a.length(), b.length());
	}
	public int getSolutionLength() {
		return solution.length();
	}
	
}
